1. Field of the Invention
The present invention relates generally to algorithms used in Error Correcting Code (ECC) applications. In particular, the present disclosure is related to implementing improved encoding and decoding techniques for ECC applications in memory technologies.
2. Description of the Related Art
In certain Error Correcting Code (ECC) applications, a Hamming metric is used to determine whether data stored in a memory device is correct or has been corrupted during a transfer process, storage process, and the like. The Hamming metric generally counts the number of positions in which a stored code word differs from a code word embedded within the data being stored. The Hamming metric does not account for or consider the error values in the identified position; instead, the Hamming metric simply indicates the number of errors that exist with respect to the code word embedded within the data being stored as compared to the code word read back from storage or the memory device. For example, given the alphabet set {0, 1, 2, 3}, if a 5-symbol long stored code word is x=1 2 1 3 2, and if the code word embedded in the data is y=2 2 1 1 2, the Hamming metric indicates that two errors exist between the two code words. That is, code word y differs from code word x in positions 1 and 4, and therefore two errors exist.
When the probability of the amount of error change between any pair of symbols in the code word is approximately the same, the Hamming metric may provide an efficient way to detect errors. However, in situations where there is a higher probability that the error value change between the two code words is relatively small (e.g., change of +/−1), it may be beneficial to incorporate an algorithm or metric into the ECC that accounts for the high likelihood of relatively small error value changes to provide a more efficient ECC. By accounting for the scenario in which small error value changes are more likely to occur as compared to larger error value changes, a more memory-efficient ECC may be used to maintain the integrity of the data being stored.